<html xmlns="http://www.w3.org/1999/xhtml"
	xmlns:h="http://java.sun.com/jsf/html"
	xmlns:f="http://java.sun.com/jsf/core"
        xmlns:c="http://java.sun.com/jstl/core" 
        xmlns:p="http://primefaces.org/ui"
        xmlns:ui="http://java.sun.com/jsf/facelets"
        
        >

    <ui:composition template="template.xhtml">
        <ui:define name="content">
  <div id="body">
        <div class="panel">

            <h2>Sign In</h2>

            <h:messages layout="table" styleClass="error"/>

            <p><b>Are you a returning customer ?</b></p>

            <TABLE cellSpacing="0" cellPadding="20" width="100%" border="1">
                <TR>
                    <TD vAlign="top">
                        <h:form>
                            
                    <h:panelGrid id="grid" columns="2">
        <h:outputText value="Login: " />
        <p:inputText value="#{account.login}" maxlength="10" size="12" />

        <h:outputText value="Password: " />
        
        <p:password  value="#{account.password}" maxlength="10" size="12" />  

        <p:commandButton value="Sign In" action="#{account.doSignIn}"
                                                         type="submit"/>
    </h:panelGrid>
                        </h:form>
                        
                    </TD>
                    <p:messages id="messages"  autoUpdate="true"/>  
                    <TD vAlign="top">
        <h:form id="form2">
    <h:panelGrid id="grid" columns="2">
        <h:outputText value="Login: " />
        <p:inputText value="#{account.customer.login}" maxlength="10" size="12" />

        <h:outputText value="Password: " />
        
        <p:password  value="#{account.customer.password}" maxlength="10" size="12" />  

        <h:outputText value="Password (Repeat):" />
        <p:password  value="#{account.password2}" maxlength="10" size="12" /> 
       <p:commandButton id="submitButton" value="Create new account" action="#{account.doCreateNewAccount}"
                                                         type="submit"/>
    </h:panelGrid>

  

                        </h:form>
                    </TD>
                </TR>
            </TABLE>
        </div>
    </div>


            
</ui:define>
	
        
    </ui:composition>
</html>